//@author A0078695H
#include "CmdAdd.h"
#include <iostream>
#include <cstring>

CmdAdd::~CmdAdd(void)
{
}
CmdAdd::CmdAdd(cmdTypes cmdType, vector<string> params, string origStr): 
		Cmd(cmdType, params, origStr) {
		if (params.size() != 1) throw "can't create CmdAdd";
		assert(params.size() == 1);
		Task task = Parser::stringToTask(params[0]);
		myTask = task;
		
}
CmdAdd::CmdAdd(cmdTypes cmdType,Task task, vector<string> params, string origStr): 
	Cmd(cmdType, params, origStr) {
	myTask = task;
}

Task CmdAdd::getTask() {
	return myTask;
}
